Abstract The proposed study is a Type 1 hybrid effectiveness-implementation trial. Early adopters from the Maryland extended-release naltrexone (XR-NTX) initiative and additional counties who are willing to provide CAM2038, a new extended-release-buprenorphine (XR-B) formulation will participate in a randomized controlled trial conducted in 7 counties (10 jails) throughout the state of Maryland, in which 240 incarcerated men and women will be randomly assigned within gender within jail to one of two groups: Arm 1. XR-B (n=120). XR-B in jail followed by 6 monthly injections post-release at a community treatment program. Arm 2. XR-NTX (n=120). One injection of XR-NTX in jail, followed by 6 monthly injections post-release at a community treatment program. Aim 1. To determine the effectiveness of XR-B compared to XR-NTX in terms of: Primary. (a) pharmacotherapy adherence (number of monthly injections received). Secondary. (b) illicit opioid urine test results; (c) self-reported illicit opioid use; (d) overdose events (non-fatal and fatal); (e) quality of life (i. physical health; ii. mental health); (f) HIV risk behaviors (i. sexual behavior; ii. needle use or sharing); and (g) criminal activity (i. crime days; ii. re-arrest; iii. re-incarceration). Aim 2. To use a learning collaborative involving all 7 RCT county jurisdictions as well as 3 additional counties that selected not to participate in the randomized trial to understand factors related to: (a) acceptability of providing long-acting agonists and antagonists in jail settings; and (b) feasibility of providing medication continuity of care from jail to community treatment providers. Aim 3. Calculate the cost to the correctional health system of implementing an XR-B or XR-NTX program, and determine the relative value of each strategy, including the costs associated with the subsequent interventions in the community, from a state- policymaker and societal perspective. The proposed study is innovative because it would be the first randomized clinical trial in the US assessing effectiveness of receiving XR-B vs. XR-NTX in county jails. The public health impact of the study will be highly significant and far-reaching because most individuals with OUD do not receive treatment while incarcerated, thereby substantially raising their likelihood of relapse to drug use, overdose death, HIV/AIDS infection, and re-incarceration. Finally, understanding how to expand acceptance of medications for opioid use disorder in jails, particularly long-acting medications, has far-reaching implications for treatment expansion in this population.